f = open('text.html','r',encoding='utf-8')
data = f.read()
f.close()

from lxml import etree

html = etree.HTML(data)
print(html.xpath("/html/body/div/@class" ))
